package a.f.c;

import a.c.bb;
import a.c.e;
import a.d.s;
import a.f.o;

import java.awt.geom.Rectangle2D;

public class k
  extends j
{
  private Object h;
  private double i;
  private double j;
  private double k = 0.5D;
  private double l = 0.5D;
  public static boolean m;
  
  public k()
  {
    this(i.e);
  }
  
  public k(Object paramObject)
  {
    this.h = paramObject;
  }
  
  public Rectangle2D a(o paramo, e parame, bb parambb)
  {
    boolean bool = h.j;
    double d1 = this.i;
    double d2 = this.j;
    if (!bool) {
      if (this.h != null)
      {
        localObject = paramo.c(this.h);
        if ((bool) || (localObject != null))
        {
          s locals = (s)((a.c.k)localObject).get(parame);
          if (!bool)
          {
            if (locals != null) {
              d1 = locals.a;
            }
          }
          else {
            d2 = locals.b;
          }
        }
      }
    }
    Object localObject = super.a(paramo, parame, parambb);
    double d3 = ((Rectangle2D)localObject).getX();
    double d4 = ((Rectangle2D)localObject).getY();
    double d5 = ((Rectangle2D)localObject).getWidth();
    double d6 = ((Rectangle2D)localObject).getHeight();
    double d7;
    double d8;
    if (!bool) {
      if (d5 < d1)
      {
        d7 = d1 - d5;
        d8 = this.k * d7;
        d3 -= d8;
        d5 = d1;
      }
    }
    if ((bool) || (d6 < d2))
    {
      d7 = d2 - d6;
      d8 = this.l * d7;
      d4 -= d8;
      d6 = d2;
    }
    ((Rectangle2D)localObject).setFrame(d3, d4, d5, d6);
    return localObject;
  }
  
  public double d()
  {
    return this.k;
  }
  
  public void a(double paramDouble)
  {
    boolean bool = h.j;
    if ((bool) || (paramDouble >= 0.0D)) {
      if (!bool)
      {
        if (paramDouble <= 1.0D) {
          this.k = paramDouble;
        }
      }
      else if (!h.i) {
        return;
      }
    }
    throw new IllegalArgumentException("xAlignment must be between 0 and 1. Given alignment is: " + paramDouble);
  }
  
  public double e()
  {
    return this.l;
  }
  
  public void b(double paramDouble)
  {
    boolean bool = h.j;
    if ((bool) || (paramDouble >= 0.0D)) {
      if (!bool)
      {
        if (paramDouble <= 1.0D) {
          this.l = paramDouble;
        }
      }
      else if (!h.i) {
        return;
      }
    }
    throw new IllegalArgumentException("yAlignment must be between 0 and 1. Given alignment is: " + paramDouble);
  }
  
  public Object f()
  {
    return this.h;
  }
  
  public void b(Object paramObject)
  {
    this.h = paramObject;
  }
  
  public void a(s params)
  {
    this.i = params.a;
    this.j = params.b;
  }
  
  public s g()
  {
    return new s(this.i, this.j);
  }
}



/* Location:           E:\idea\

 * Qualified Name:     a.f.c.k

 * JD-Core Version:    0.7.0.1

 */